
package gal.game.core.layers
{
	import flash.display.Sprite;
	
	import gal.game.core.resource.GameLoader;
	
	/**
	 * @author 缺硒
	 */
	public class BackgroundLayer extends Sprite
	{
		private var _background:GameLoader;
		
		// 构造函数
		public function BackgroundLayer()
		{
			_background = new GameLoader();
			
			addChild(_background);
		}
		
		/**
		 * 转换背景
		 * @param bid 背景id 
		 */		
		public function switchBackground(bid:String):void
		{
			_background.loadElement("assets/bgd/" + bid + ".png");
		}
		//
	}
}